import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'

Vue.use(VueRouter)

const routes = [
  
      {
        path: '/',
        name: 'father',
       
        component: () => import( '../views/father.vue'),
        redirect :'/home',
        children:[
          {
            path: '/home',
            name: 'Home',
            component: Home
          },
          {
            path: '/about',
            name: 'About',
           
            component: () => import( '../views/About.vue')
          },
          {
            path: '/gou',
            name: 'gou',
           
            component: () => import( '../views/gou.vue')
          },
          {
            path: '/geren',
            name: 'geren',
           
            component: () => import( '../views/geren.vue')
          },
        ]

      },
      {
        path: '/fenlei',
        name: 'fenlei',
       
        component: () => import( '../views/fenlei.vue')
      },   

      {
        path: '/qian',
        name: 'qian',
       
        component: () => import( '../views/qian.vue')
      },   
      {
        path: '/lingjuan',
        name: 'lingjuan',
       
        component: () => import( '../views/lingjuan.vue')
      }, 
      {
        path: '/xiang',
        name: 'xiang',
       
        component: () => import( '../views/xiang.vue')
      }, 
      {
        path: '/kanjialiebiao',
        name: 'kanjialiebiao',
       
        component: () => import( '../views/kanjialiebiao.vue')
      }, 
      {
        path: '/yanxuanzhuanlan',
        name: 'yanxuanzhuanlan',
       
        component: () => import( '../views/yanxuanzhuanlan.vue')
      }, 
      {
        path: '/zhuanlanxiangqing',
        name: 'zhuanlanxiangqing',
       
        component: () => import( '../views/zhuanlanxiangqing.vue')
      }, 
      {
        path: '/renqituijian',
        name: 'renqituijian',
       
        component: () => import( '../views/renqituijian.vue')
      }, 
  
  {
    path: '/login',
    name: 'login',
   
    component: () => import( '../views/login.vue')
  },
 
]

const router = new VueRouter({
  routes
})

export default router
